#ifndef OBSERVER_H
#define OBSERVER_H


#include <iostream>
#include <vector>

using namespace std;

//================================================================================

class Subject;

class Observer {
public:
	virtual			~Observer() {}
    virtual void	Update(Subject* ChngSubject) = 0;
protected:
	Observer(Subject* sbj) {}
	Subject* sbj;
};

//================================================================================

class Subject {
public:
	virtual ~Subject(){}

    virtual void Attach(Observer*);
    virtual void Detach(Observer*);
    virtual void Notify();
protected:
	Subject() {}
	vector<Observer*> m_observers; 
private:
    
};


#endif